
import { defineStore } from 'pinia'
import { ref, computed } from 'vue'
import { ListTableCollection } from '../utils/trueType'
export const useListStore = defineStore('list', {
    state: () => ({
        tableData : [] as ListTableCollection[],
        pageNum:ref(1),
        pageSize:ref(5),
        total:0,
        isLoading:ref(false),
    }),
    actions: {
        setTableData(data: any) {
            this.tableData = data
        },
        setPageNum(data: any) {
            this.pageNum = data
        },
        setPageSize(data: any) {
            this.pageSize = data
        },
        setIsloading(loading:boolean) {
            this.isLoading = loading
        },
    },
    getters: {
        
    },
}
)